package com.qhgrain.app.vo;

import java.util.ArrayList;
import java.util.List;

public class MenuVo {

	private String id;/*菜单Id*/
	private String name;/*菜单名称*/
	private String menuUrl;/*菜单链接URL*/
	private String parentMenuId;/*所属上级菜单Id*/
	/**菜单状态（0启用，1停用）*/
	private String status;
	private String createDate;/*创建时间*/
	/**
	 * 层次
	 */
	private String levelNum;
	private String orderNum;/*同级排序*/
	
	/**
	 * 所属应用
	 */
	private String appId;


	/**
	 * 菜单权限配置
	 */
	private PermissionVo menuPermission;
	/**
	 * 菜单的功能权限配置
	 */
	private List<PermissionVo> operationPermissionList;
	
	public MenuVo(){
		
	}
	
	public MenuVo(String id, String name, String parentMenuId,String levelNum) {
		super();
		this.id = id;
		this.name = name;
		this.parentMenuId = parentMenuId;
		this.levelNum = levelNum;
	}
	
	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getMenuUrl() {
		return menuUrl;
	}

	public void setMenuUrl(String menuUrl) {
		this.menuUrl = menuUrl;
	}

	public String getParentMenuId() {
		return parentMenuId;
	}

	public void setParentMenuId(String parentMenuId) {
		this.parentMenuId = parentMenuId;
	}

	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public String getCreateDate() {
		return createDate;
	}

	public void setCreateDate(String createDate) {
		this.createDate = createDate;
	}

	public String getOrderNum() {
		return orderNum;
	}

	public void setOrderNum(String orderNum) {
		this.orderNum = orderNum;
	}

	public String getAppId() {
		return appId;
	}

	public void setAppId(String appId) {
		this.appId = appId;
	}

	public String getLevelNum() {
		return levelNum;
	}

	public void setLevelNum(String levelNum) {
		this.levelNum = levelNum;
	}

	public PermissionVo getMenuPermission() {
		return menuPermission;
	}

	public void setMenuPermission(PermissionVo menuPermission) {
		this.menuPermission = menuPermission;
	}

	
	
	public void setOperationPermission(PermissionVo permissionVo){
		if(operationPermissionList == null	){
			this.operationPermissionList = new ArrayList<PermissionVo>();
		}
		this.operationPermissionList.add(permissionVo);
	}

	public List<PermissionVo> getOperationPermissionList() {
		return operationPermissionList;
	}

	public void setOperationPermissionList(
			List<PermissionVo> operationPermissionList) {
		this.operationPermissionList = operationPermissionList;
	}
}
